package cn.edu.laud.sany.utils;

public class Config
{
	public static String CommandHelpString = "\nParameter error. Use this program like this:\n"
			+ "\njava -jar *.jar --thread 10 --schema 1 --type recreate --laudport 9160 --laudip 192.168.106.220,192.168.106.221 --replica 2 --keyspace sany1 --csvpath 31data --cfsfile cfs.txt \n"
			+ "\n\t--thread\t<int>    \tThread number, the program will create <int> threads to import data."
			+ "\n\t--schema\t<1/2>  \tChoose which schema will be used. read the Schema text to get more details."
			+ "\n\t--type  \t<new/append/clear/recreate> \t decide whether delete the schema/data or not.  read the Type text to get more details."
			+ "\n\t--laudport\t<int>   \tThe laud port, default 9160"
			+ "\n\t--laudip \t<string>  \tThe laud server ips, use ',' to split each ip."
			+ "\n\t--replica\t<true/false> \tLaud replication factor for this keyspace."
			+ "\n\t--keyspace\t<string> \tThe keyspace which will be import data into(default laud_sany_case_<schema>)."
			+ "\n\t--csvpath\t<fileName> \tThe csv input file's path."
			+ "\n\t--cfsfile \t<fileName> \tThe column familys' name list file"
			+ "\n\t[--compress] \t<0/1> \tWhether compress the csv file to tar.gz or not"
			+ "\n\t[--ignorefile] \t<fileName> \tThe ignore paraIds' file, can be null"
			+ "\n\t[--errorStop] \t<0/1> \tStop(1) or contine(0 default) to import when getting error format data"
			+ "\n\t[--comparator] \t<LongTypeDesc/LongTypeDesc/...> \tComparator Type for column name"
			+ "\n\t[--transcation] \t<ALL/ANY/ONE> \tTranscation Type for executing CQL";
	
	public static String ReadTestCommandHelpString = "\nParameter error. Use this program like this:\n"
			+ "\njava -jar *.jar --thread 10 --laudport 9160 --laudip 192.168.106.220,192.168.106.221 --keyspace sany1 --equipfile equip.txt --cfsfile cfs.txt --testtype 1 --querydate query.txt --repeat 1000 --oridata 10000\n"
			+ "\n\t--thread\t<int>    \tThread number, the program will create <int> threads to import data."
			+ "\n\t--laudport\t<int>   \tThe laud port, default 9160"
			+ "\n\t--laudip \t<string>  \tThe laud server ips, use ',' to split each ip."
			+ "\n\t--keyspace\t<string> \tThe keyspace which will be import data into. default laud_sany_case_<schema>"
			+ "\n\t--equipfile\t<fileName> \tThe equip id list file."
			+ "\n\t--cfsfile \t<fileName> \tThe column familys' name list file"
			+ "\n\t--testtype \t<1/2> \t1 for large table query test; 2 and 3 for hot table query test."
			+ "\n\t--querydate \t<fileName> \t[if testtype=1]The start and end query date of each test case in each line, use comma to split them. If testtype=1 this param can be null."
			+ "\n\t--queryhot \t<int> \t[if testtype=2,3]The random query count of equipId/paraId in hot table."
			+ "\n\t--repeat \t<int> \tThe repeat times to test of every thread."
			+ "\n\t--oridata \t<int> \tThe quantity of original data online, just to name result file.";
	
	public static final int InitLaudPort = 9160;
	public static String JDBCFormat = "jdbc:cassandra://%s:%d?version=2.0.0";
	public static String CFComparatorTypePrefix = "org.apache.cassandra.db.marshal.";
	public static String CFComparatorType0 = "org.apache.cassandra.db.marshal.LongTypeDesc";
	public static String CFCalidationClass = "org.apache.cassandra.db.marshal.UTF8Type";
	public static String KSStrategy = "org.apache.cassandra.locator.SimpleStrategy";
	public static String CFNameFormat0 = "cf_%s";
	public static String CFNameFormat1 = "cf_gk_%s";
	public static String CFNameFormat2 = "cf_qzj_%s";
	public static String CFPrimaryKeyAlias0 = "key";
	public static String CFPrimaryKeyAlias1 = "equip";
	public static String CFPrimaryKeyAlias2 = "qzj";
	public static String CQLInsertFormat0 = "insert into cf_%d (key, %d) values ('%s', '%s');";
	public static String CQLInsertFormat1 = "insert into cf_gk_%d (equip, %d) values ('%s', '%s');";
	public static String CQLInsertFormat2 = "insert into cf_qzj_%d (qzj, %d) values ('%s', '%s');";
}
